﻿Imports Entidades

Public Class Objeto : Implements IEquatable(Of Objeto)
    Public Property IdFamilia As String
    Public Property NumeroFamilia As Integer
    Public Property IdEntrega As Integer
    Public Property Valoracion As Double
    Public Property Tamaño As String
    Public Property NumeroSerie As String
    Public Property Descripcion As String
    Public Property dadoDeBaja As Boolean


    Public Sub New()

    End Sub
    Public Sub New(idfamilia As String, numerofamilia As Integer, idbolsa As Integer, puntos As Double, tamañotalla As String, numSerie As String, descripcion As String)
        Me.IdEntrega = idbolsa
        Me.IdFamilia = idfamilia
        Me.Valoracion = puntos
        Me.Tamaño = tamañotalla
        Me.NumeroFamilia = numerofamilia
        Me.NumeroSerie = numSerie
        Me.Descripcion = descripcion


    End Sub


    Public Sub New(idfamilia As String, numerofamilia As Integer, idbolsa As Integer, puntos As Double, tamañotalla As String, numSerie As String, descripcion As String, baja As Boolean)
        Me.IdEntrega = idbolsa
        Me.IdFamilia = idfamilia
        Me.Valoracion = puntos
        Me.Tamaño = tamañotalla
        Me.NumeroFamilia = numerofamilia
        Me.NumeroSerie = numSerie
        Me.Descripcion = descripcion
        Me.dadoDeBaja = baja

    End Sub


    Public Overloads Function Equals(other As Objeto) As Boolean Implements IEquatable(Of Objeto).Equals
        Return other IsNot Nothing AndAlso other.IdEntrega = Me.IdEntrega AndAlso other.IdFamilia = Me.IdFamilia

    End Function
End Class
